﻿using System;
using System.Collections.Generic;
using System.Text;

namespace SHKF.B2C.WanLiNiu.Model.Inter.OpenTradeListTrades
{
   public  class OpenTradeData
    {
        /// <summary>
        /// 账号
        /// </summary>
        public string buyer_account { get; set; }

        /// <summary>
        /// 单据主键(唯一)
        /// </summary>
        public string uid { get; set; }

        public string buyer_mobile { get; set; }

        /// <summary>
        /// 留言
        /// </summary>
        public string buyer_msg { get; set; }

        /// <summary>
        /// 省
        /// </summary>
        public string province { get; set; }

        /// <summary>
        /// 市
        /// </summary>
        public string city { get; set; }

        /// <summary>
        /// 区
        /// </summary>
        public string district { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        public long create_time { get; set; }

        /// <summary>
        /// 原始货币种类
        /// </summary>
        public string currency_code { get; set; }

        /// <summary>
        /// 原始货币金额
        /// </summary>
        public decimal currency_sum { get; set; }

        /// <summary>
        /// 优惠金额
        /// </summary>
        public string discount_fee { get; set; }

        /// <summary>
        /// 完成时间：交易结束或交易成功的时间
        /// </summary>
        public long end_time { get; set; }

        /// <summary>
        /// 审核时间
        /// </summary>
        public long approve_time { get; set; }

        /// <summary>
        /// 快递单号
        /// </summary>
        public string express_code { get; set; }

        /// <summary>
        /// 旗子颜色0:无1：红2：黄3：绿4：蓝5：粉
        /// </summary>
        public int flag { get; set; }

        /// <summary>
        /// 退款标记 0:否；1:是
        /// </summary> 
        public int has_refund { get; set; }

        public Invoice invoice { get; set; }

        /// <summary>
        /// 是否异常订单
        /// </summary>
        public bool is_exception_trade { get; set; }

        /// <summary>
        /// 是否已付款
        /// </summary>
        public bool is_pay { get; set; }

        /// <summary>
        /// 是否jit小单
        /// </summary>
        public bool is_small_trade { get; set; }

        /// <summary>
        /// 安装服务商编码-- 淘系家装类订单字段
        /// </summary>
        public string jz_install_code { get; set; }

        public string jz_install_name { get; set; }

        public string jz_server_code { get; set; }
        public string jz_server_name { get; set; }

        /// <summary>
        /// 万里牛ERP快递公司代码，用户自定义代码
        /// </summary>
        public string logistic_code { get; set; }
        public string mark { get; set; }

        /// <summary>
        /// 0 快递 1 EMS 2 平邮 11 虚拟商品 121 自提 122 商家自送 125 同城限时达 -1 其它
        /// </summary>
        public int tp_logistics_type { get; set; }

        /// <summary>
        /// 体积 单位：立方米
        /// </summary>
        public decimal volume { get; set; }

        /// <summary>
        /// 重量 单位：千克
        /// </summary>
        public decimal weight { get; set; }

        /// <summary>
        /// 客户编码
        /// </summary>
        public string buyer_code { get; set; }

        /// <summary>
        /// 买家渠道昵称
        /// </summary>
        public string channel_name { get; set; }

        /// <summary>
        /// 身份证名称
        /// </summary>
        public string identity_name { get; set; }

        /// <summary>
        /// 身份证信息
        /// </summary>
        public string identity_num { get; set; }

        /// <summary>
        /// 快递成本,数值可能会变动(如果设置了运费计算规则，订单审核后会根据商品估量和运费规则计算运费成本,称重后根据实际重量重新计算！页面也能直接修改)
        /// </summary>
        public decimal post_cost { get; set; }

        /// <summary>
        /// 修改时间
        /// </summary>
        public long modify_time { get; set; }

        /// <summary>
        /// 明细线上单号集合
        /// </summary>
        public List<string> oln_order_list { get; set; }

        /// <summary>
        /// 线上状态:1:等待付款 2:等待发货 ,部分发货 3:已完成 4:已关闭 5: 等待确认 6:已签收 0: 未建交易
        /// </summary>
        public int oln_status { get; set; }

        /// <summary>
        /// 应收款
        /// </summary>
        public decimal paid_fee { get; set; }

        public bool shipped_without_system { get; set; }

        /// <summary>
        /// 买家实付
        /// </summary>
        public decimal real_payment { get; set; }

        /// <summary>
        /// wms配货页面的订单状态
        /// </summary>
        public string wms_push_status { get; set; }

        //外部支付单号
        public string pay_no { get; set; }

        /// <summary>
        /// 付款时间
        /// </summary>
        public long pay_time { get; set; }

        /// <summary>
        /// 支付类型
        /// </summary>
        public string pay_type { get; set; }

        /// <summary>
        /// 手机号，手机号为空的时候返回电话
        /// </summary>
        public string phone { get; set; }

        /// <summary>
        /// post_fee
        /// </summary>
        public decimal post_fee { get; set; }

        /// <summary>
        /// 打印备注
        /// </summary>
        public string print_remark { get; set; }

        /// <summary>
        /// 万里牛单据处理状态:
        /// -3:分销商审核 
        /// -2:到账管理 
        /// -1:未付款 
        /// 0:审核 
        /// 1:打单配货 
        /// 2:验货 
        /// 3:称重 
        /// 4:待发货 
        /// 5：财审 
        /// 8:已发货 
        /// 9:成功 
        /// 10:关闭 
        /// 11:异常结束 
        /// 12:异常处理 
        /// 13:外部系统配货中 
        /// 14:预售 
        /// 15:打包
        /// 19:拣货
        /// </summary>
        public int process_status { get; set; }

        public string remark { get; set; }

        //是否拆分订单
        public bool split_trade { get; set; }

        /// <summary>
        /// 业务员
        /// </summary>
        public string sale_man { get; set; }

        /// <summary>
        /// 卖家留言址
        /// </summary>
        public string seller_msg { get; set; }

        /// <summary>
        /// 发货时间
        /// </summary>
        public long send_time { get; set; }

        /// <summary>
        /// 服务费
        /// </summary>
        public decimal service_fee { get; set; }

        public string shop_id { get; set; }

        /// <summary>
        /// 店铺名称(页面上显示)
        /// </summary>
        public string shop_name { get; set; }

        /// <summary>
        /// 店铺昵称(店铺唯一)
        /// </summary>
        public string shop_nick { get; set; }

        /// <summary>
        /// 店铺类型
        /// </summary>
        public int shop_type { get; set; }

        /// <summary>
        /// 店铺来源
        /// </summary>
        public string source_platform { get; set; }

        /// <summary>
        /// 状态：1：处理中 2：发货 3：完成 4: 关闭 5:其他
        /// </summary>
        public int status { get; set; }

        /// <summary>
        /// 仓库编码
        /// </summary>
        public string storage_code { get; set; }


        /// <summary>
        /// 仓名称
        /// </summary>
        public string storage_name { get; set; }

        /// <summary>
        /// 总金额,包含优惠
        /// </summary>
        public decimal sum_sale { get; set; }

        /// <summary>
        /// 电话
        /// </summary>
        public string tel { get; set; }

        /// <summary>
        /// 线上单号,如果是线下订单，则是万里牛的单号，合单情况下会将单号合并，使用|做分隔
        /// </summary>
        public string tp_tid { get; set; }

        /// <summary>
        /// 波次号
        /// </summary>
        public string wave_no { get; set; }

        /// <summary>
        /// 订单编码
        /// </summary>
        public string trade_no { get; set; }

        /// <summary>
        /// 订单类型 :
        /// 1:普通线上订单 
        /// 5：货到付款 
        /// 6：分销 
        /// 7：团购类型
        /// 9：天猫国际物流订单类型 
        /// 50：普通线下订单 
        /// 51：售后订单（一般换货创建的订单）
        /// </summary>
        public int trade_type { get; set; }

        /// <summary>
        /// 邮编
        /// </summary>
        public string zip { get; set; }

        public string logistic_name { get; set; }

        //平台返回预计发货时间
        public long estimate_send_time { get; set; }

        /// <summary>
        /// 原币运费金额
        /// </summary>
        public decimal post_currency { get; set; }

        public string sale_man_mobile { get; set; }

        public string extend_info { get; set; }

        public List<Order> orders { get; set; }
    }
}
